export function GetNow(date) {
    let nowStr = ""
    var year = date.getFullYear() // 年
    var month = date.getMonth() + 1; // 月
    var day = date.getDate(); // 日
    var hour = date.getHours(); // 时
    var minutes = date.getMinutes(); // 分
    var seconds = date.getSeconds();; //秒
    // 给一位数的数据前面加 “0”
    if (month >= 1 && month <= 9) {
        month = "0" + month;
    }
    if (day >= 0 && day <= 9) {
        day = "0" + day;
    }
    if (hour >= 0 && hour <= 9) {
        hour = "0" + hour;
    }
    if (minutes >= 0 && minutes <= 9) {
        minutes = "0" + minutes;
    }
    if (seconds >= 0 && seconds <= 9) {
        seconds = "0" + seconds;
    }
    nowStr = year + "/" + month + "/" + day + " " + hour + ":" + minutes + ":" + seconds
    return nowStr
}

export function GetNow59(date) {
    let nowStr = ""
    var year = date.getFullYear() // 年
    var month = date.getMonth() + 1; // 月
    var day = date.getDate(); // 日
    var hour = "23"; // 时
    var minutes = "59"; // 分
    var seconds = "59"; //秒
    nowStr = year + "/" + month + "/" + day + " " + hour + ":" + minutes + ":" + seconds
    return nowStr
}
export function GetNow_00(date) {
    let nowStr = ""
    var year = date.getFullYear() // 年
    var month = date.getMonth() + 1; // 月
    var day = date.getDate(); // 日
    var hour = "00"; // 时
    var minutes = hour; // 分
    var seconds = hour //秒
    nowStr = year + "/" + month + "/" + day + " " + hour + ":" + minutes + ":" + seconds
    return nowStr
}